package svc

import (
	"furniture/api/internal/config"
	"furniture/furniturerpc/furniturerpcclient"
	"github.com/zeromicro/go-zero/zrpc"
)

type ServiceContext struct {
	Config       config.Config
	FurnitureRpc furniturerpcclient.Furniturerpc
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config:       c,
		FurnitureRpc: furniturerpcclient.NewFurniturerpc(zrpc.MustNewClient(c.FurnitureRpc)),
	}
}
